<form id="add-form" class="form-horizontal" role="form" data-toggle="validator" method="POST" action="">
    
    <div class="panel-body">
        <div id="myTabContent" class="tab-content" >
            <div class="tab-pane fade active in" id="tabs_0">
                <input type="hidden" name="row[id]" value="" class="form-control" data-rule="" data-tip="id"  />

                <div class="form-group">
                    <label for="c-title" class="control-label col-xs-12 col-sm-2">项目名称:</label>
                    <div class="col-xs-12 col-sm-8" id="div-title">
                        <input type="text" id="c-title" name="row[title]" value="" class="form-control" title="title" placeholder="请输入项目名称" data-rule="required" data-tip="项目名称" />
                    </div>
                </div>

                <div class="form-group">
                    <label for="c-start_time" class="control-label col-xs-12 col-sm-2">活动开始时间:</label>
                    <div class="col-xs-12 col-sm-8" id="div-start_time">
                        <input type="text" id="c-start_time" name="row[start_time]" value="" class="form-control datetimepicker" placeholder="请选择活动开始时间" data-rule="required" data-tip="活动开始时间" />
                    </div>
                </div>

                <div class="form-group">
                    <label for="c-end_time" class="control-label col-xs-12 col-sm-2">活动结束时间:</label>
                    <div class="col-xs-12 col-sm-8" id="div-end_time">
                        <input type="text" id="c-end_time" name="row[end_time]" value="" class="form-control datetimepicker" placeholder="请选择活动结束时间" data-rule="required" data-tip="活动结束时间" />
                    </div>
                </div>

                <div class="form-group">
                    <label for="c-intro" class="control-label col-xs-12 col-sm-2">课程介绍:</label>
                    <div class="col-xs-12 col-sm-8" id="div-intro">
                        <textarea name="row[intro]" id="c-intro" class="form-control editor" data-rule="required" rows="5" data-tip="课程介绍" placeholder="请输入课程介绍"></textarea>
                    </div>
                </div>


                <div class="form-group">
                    <label class="control-label col-xs-12 col-sm-2">是否指定班级:</label>
                    <div class="col-xs-12 col-sm-8" id="div-is_classes">
                        <input id="c-is_classes" name="row[is_classes]" type="hidden" value="0">
                        <a href="javascript:;" data-toggle="switcher" class="btn-switcher" data-input-id="c-is_classes" data-yes="1" data-no="0">
                            <i class="fa fa-toggle-on text-success fa-flip-horizontal fa-2x"></i>
                        </a>
                        <div data-favisible="switch=1" class="p-3">是</div>
                        <div data-favisible="switch=0" class="p-3">否</div>
                    </div>
                </div>

                <div class="form-group" id="class-items-group" style="display:none;">
                    <label for="c-classes_ids" class="control-label col-xs-12 col-sm-2">指定班级:</label>
                    <div class="col-xs-12 col-sm-8" id="div-class_items">
                        <select name="row[classes_ids][]" id="c-classes_ids" class="form-control selects" multiple>
                        </select>
                    </div>
                </div>

                <div class="form-group">
                    <label for="c-max_num" class="control-label col-xs-12 col-sm-2">名额:</label>
                    <div class="col-xs-12 col-sm-8" id="div-max_num">
                        <input type="number" id="c-max_num" name="row[max_num]" value="30" class="form-control" placeholder="请输入名额数量" data-rule="required|digits" data-tip="名额" min="1" />
                    </div>
                </div>

                <div class="form-group">
                    <label for="c-cover" class="control-label col-xs-12 col-sm-2">封面图:</label>
                    <div class="col-xs-12 col-sm-8" id="div-cover">
                        <div class="form-inline">
                            <input id="c-cover" class="form-control" size="38" name="row[cover]" type="text" value="" data-tip="">
                            <span>
                                <button type="button" id="plupload-cover" class="btn btn-danger plupload" data-input-id="c-cover" data-mimetype="image/*" data-multiple="false" data-preview-id="p-cover">
                                    <i class="fa fa-upload"></i> {:__('Upload')}
                                </button>
                            </span>
                            <span>
                                <button type="button" id="fachoose-cover" class="btn btn-primary fachoose" data-input-id="c-cover" data-mimetype="image/*" data-multiple="false">
                                    <i class="fa fa-list"></i> {:__('Choose')}
                                </button>
                            </span>
                            <ul class="row list-inline plupload-preview" id="p-cover"></ul>
                        </div>
                    </div>
                </div>

                <div class="form-group">
                    <label class="control-label col-xs-12 col-sm-2">状态:</label>
                    <div class="col-xs-12 col-sm-8" id="div-status">                    
                        <input id="c-status" name="row[status]" type="hidden" value="1">
                        <a href="javascript:;" data-toggle="switcher" class="btn-switcher active" data-input-id="c-status" data-yes="1" data-no="0">
                            <i class="fa fa-toggle-on text-success fa-2x"></i>
                        </a>
                        <div data-favisible="switch=1" class="p-3">正常</div>
                        <div data-favisible="switch=0" class="p-3">禁用</div>
                    </div>
                </div>

                <div class="form-group layer-footer">
                    <label class="control-label col-xs-12 col-sm-2"></label>
                    <div class="col-xs-12 col-sm-8">
                        <button type="submit" class="btn btn-success btn-embossed disabled">{:__('OK')}</button>
                        <button type="reset" class="btn btn-default btn-embossed">{:__('Reset')}</button>
                    </div>
                </div>
            </div>
            
        </div>
    </div>
</form>